package com.hsmpay.mobile.ds;

import com.hsmpay.common.pojo.qian4.Qian4SendLog;
import com.hsmpay.mobile.pojo.terminal.Tchannel;
import com.hsmpay.qian4.pojo.BalanceResult;
import com.hsmpay.qian4.pojo.PurchaseResult;
import com.hsmpay.qian4.pojo.RevocationResult;

import java.io.Serializable;
import java.util.Map;

/**
 * 瑞升银联代收接口
 *
 * @param <Entity>
 * @param <Query>
 * @author 颜铃璋
 *         创建时间：2014-11-14
 */
public interface DS_RuiShengService<Entity extends Serializable, Query extends Object> {
    /**
     * 获取瑞升银联socket 接口密钥
     *
     * @param str
     * @return
     * @throws Exception
     */
    public Map<String, String> getMiYao(String str, String transAmt, Double c_fdMoney) throws Exception;

    /**
     * 刷新瑞升银联socket 接口密钥
     *
     * @param str
     * @return
     * @throws Exception
     */
    public Map<String, String> reflushMiYao(String transAmt, Double c_fdMoney) throws Exception;

    /**
     * 查询瑞升银联订单号
     *
     * @return
     * @throws Exception
     */
    public Integer searchRuiShengTransId() throws Exception;

    /**
     * 费率版收款
     *
     * @param send
     * @param roleId
     * @return
     * @throws Exception
     */
    public PurchaseResult billPayment(Qian4SendLog send, Tchannel tc) throws Exception;

    /**
     * 冲正
     *
     * @param send
     * @return
     * @throws Exception
     */
    public RevocationResult unBillPayment(Qian4SendLog send) throws Exception;

    /**
     * 初始化 请求参数
     *
     * @param send
     * @param tc
     * @param otherParam
     * @return
     * @throws Exception
     */
    public Qian4SendLog initSend(Qian4SendLog send, Tchannel tc) throws Exception;

    /**
     * 查询余额
     *
     * @param send
     * @param otherParam
     * @return
     * @throws Exception
     */
    public BalanceResult balanceEnquiry(Qian4SendLog send) throws Exception;

}
